unit uFrmFastReport;

interface

uses
    Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
    types, uFrmSampleFastReport,Dialogs,  FR_DSet, FR_DBSet, FR_Class,FR_Ctrls
    , FR_Dock,FR_ChBox,FR_Rich,FR_Shape,FR_BarC,FR_BndEd,FR_Combo,FR_DCtrl

  {frxClass, frxDBSet, frxDesgn,frx2xto30};

type
    TFrmFastReport = class( TFrmSampleFastReport )
//    frxdsgnr1: TfrDesigner;
        procedure ReportBeginPage( pgNo: Integer );
        procedure FormCreate( Sender: TObject );
    private
        FConditionString: string;
    public
        property ConditionString: string read FConditionString write
            FConditionString;
    end;

implementation

{$R *.dfm}

const
    MEMO_NAME_OF_CONDITION = '${conditions}';

procedure TFrmFastReport.ReportBeginPage( pgNo: Integer );
var
    MemoCondition        : TfrView;
begin
    inherited;
    MemoCondition := frxrprtreport.FindObject( MEMO_NAME_OF_CONDITION );
    if ( MemoCondition <> nil ) and ( MemoCondition is TfrView ) then
        with MemoCondition as TfrMemoView do
            Memo.Text := FConditionString;
end;

procedure TFrmFastReport.FormCreate( Sender: TObject );
begin
    inherited;
//    frxrprtreport..PrintToDefault := false;
end;

end.
